package com.cd.university.db.mapper;

import com.cd.university.db.pojo.UserLoginLog;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.HashMap;
import java.util.List;

@Mapper
public interface UserLoginLogMapper {
    int deleteByPrimaryKey(Date loginTime);

    int insert(UserLoginLog record);

    int insertSelective(UserLoginLog record);

    UserLoginLog selectByPrimaryKey(Date loginTime);

    int updateByPrimaryKeySelective(UserLoginLog record);

    int updateByPrimaryKey(UserLoginLog record);

    public List<UserLoginLog> getUserLoginLogAll();

    /**
     * 根据时间筛选日志
     * @param startTime 起始时间
     * @param endTime 结束时间
     * @return 用户日志集合
     */
    public List<UserLoginLog> searchByTime(@Param("startTime") Date startTime,
                                           @Param("endTime") Date endTime);
}
